//Function:show the usage of function template.
#include <iostream>
using namespace std;
template <class T>
T maximum(T value1, T value2, T value3);
int main()
{
	int int1=0,int2=0,int3=0;
	double double1=0,double2=0,double3=0;
	
	cout << "Enter the int number of three:" << endl;
	cin >> int1 >> int2 >> int3;
	cout << "The maximum number is :" << maximum(int1,int2,int3) << endl;
	
	cout << "Enter the double number of three:" << endl;
	cin >> double1 >> double2 >> double3;
	cout << "The maximum number is :" << maximum(double1,double2,double3) << endl;
}

template <class T>
T maximum(T value1, T value2, T value3)
{
	T max = value1;
	if(value2 > max)
		max = value2;
	if(value3 > max)
		max = value3;
	return max;
}                          
